<?php

namespace App\Models\Income;

use App\Models\Model;

class IncomeCharteredCarFixed extends Model
{
    protected $table = 'akbus_income_chartered_fixed';

    protected $fillable = [
        'date',
        'chartered_income',
    ];

    /**
     * 格式化日期
     *
     * @param  string  $value
     *
     * @return string
     */
    public function getDateAttribute($value)
    {
        return substr($value, 0, 7);
    }
}
